Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(terraform): allow dev environment to push to S3 email bucket #208

Merged
merged 2 commits into from
Aug 5, 2024

Conversation

JoshuaLicense
Copy link
Contributor

Description

Fixes the permission denied when sending emails on dev.

Related issue: https://dvsa.atlassian.net/browse/VOL-5681

Before submitting (or marking as "ready for review")

  • Does the pull request title follow the conventional commit specification?
  • Have you performed a self-review of the code
  • Have you have added tests that prove the fix or feature is effective and working
  • Did you make sure to update any documentation relating to this change?

@JoshuaLicense JoshuaLicense self-assigned this Aug 2, 2024
Copy link
Contributor

github-actions bot commented Aug 2, 2024

Terraform plan for environment: dev

Commit: c2d9271

API version: 418eb0c
CLI version: 418eb0c
Selfserve version: 418eb0c
Internal version: 418eb0c

Plan summary

0 to add, 1 to change, 0 to destroy

🔄 Updates

module.service.module.ecs_service["api"].aws_iam_role_policy.tasks[0]

Show full plan
Terraform used the selected providers to generate the following execution
plan. Resource actions are indicated with the following symbols:
  ~ update in-place

Terraform will perform the following actions:

  # module.service.module.ecs_service["api"].aws_iam_role_policy.tasks[0] will be updated in-place
  ~ resource "aws_iam_role_policy" "tasks" {
        id          = "vol-app-dev-api-service-20240418150301374200000005:vol-app-dev-api-service-20240430142821580100000003"
        name        = "vol-app-dev-api-service-20240430142821580100000003"
      ~ policy      = jsonencode(
          ~ {
              ~ Statement = [
                    # (5 unchanged elements hidden)
                    {
                        Action   = [
                            "sqs:SendMessageBatch",
                            "sqs:SendMessage",
                            "sqs:ReceiveMessage",
                            "sqs:PurgeQueue",
                            "sqs:ListDeadLetterSourceQueues",
                            "sqs:GetQueueAttributes",
                            "sqs:DeleteMessageBatch",
                            "sqs:DeleteMessage",
                        ]
                        Effect   = "Allow"
                        Resource = [
                            "arn:aws:sqs:eu-west-1:054614622558:DEVAPPDEV-OLCS-PRI-CHGET-INSOLVENCY-DLQ",
                            "arn:aws:sqs:eu-west-1:054614622558:DEVAPPDEV-OLCS-PRI-CHGET-INSOLVENCY",
                            "arn:aws:sqs:eu-west-1:054614622558:DEVAPPDEV-OLCS-PRI-CHGET-DLQ",
                            "arn:aws:sqs:eu-west-1:054614622558:DEVAPPDEV-OLCS-PRI-CHGET",
                        ]
                    },
                  + {
                      + Action   = "s3:PutObject"
                      + Effect   = "Allow"
                      + Resource = "arn:aws:s3:::devapp-olcs-pri-olcs-autotest-s3/*"
                    },
                ]
                # (1 unchanged attribute hidden)
            }
        )
        # (2 unchanged attributes hidden)
    }

Plan: 0 to add, 1 to change, 0 to destroy.

@JoshuaLicense JoshuaLicense changed the title feat(terraform): allow dev environment to push to S3 email bucket fix(terraform): allow dev environment to push to S3 email bucket Aug 2, 2024
@JoshuaLicense JoshuaLicense merged commit a33198c into main Aug 5, 2024
18 checks passed
@JoshuaLicense JoshuaLicense deleted the add-permissions-to-email-s3-bucket branch August 5, 2024 09:41
cmarstondvsa pushed a commit that referenced this pull request Aug 5, 2024
matbeales pushed a commit that referenced this pull request Aug 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants